package com.wlz.controller;


import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/demo")
public class TestController {

    @Value(value = "${test.name}")
    private String name;

    @Value(value = "${test.password}")
    private String password;

    @Value(value = "${test.age}")
    private Integer age;


    @RequestMapping("/hello")
    public String hello() {
        return "这是nacos 配置 name: " + name + "     passwod: " + password + "  age: " + age;
    }
}
